home *** CD-ROM | disk | FTP | other *** search
/ Language/OS - Multiplatform Resource Library / LANGUAGE OS.iso / cpp_libs / answrbok / 3_7.lha / 3_7 / 3_7ctst.c < prev    next >
Text File  |  1993-08-08  |  483b  |  24 lines

  1. * Copyright (c) 1990 by AT&T Bell Telephone Laboratories, Incorporated. */
  2. * The C++ Answer Book */
  3. * Tony Hansen */
  4. * All rights reserved. */
  5. include <stream.h>
  6. include "3_7c.c"
  7.  
  8. har *x[] =
  9.    {
  10.    "hello there",
  11.    "",
  12.    "This is a test",
  13.    "The quick brown fox jumped over the lazy brown dog",
  14.    0
  15.    };
  16.  
  17. ain()
  18.  
  19.    for (int i = 0; i < 17; i += 4)
  20. for (char **xp = x; *xp; xp++)
  21.     cout << "str='" << *xp << "', max=" << i << ", len=" << strnlen(*xp, i) << "\n";
  22.    return 0;
  23.  
  24.